package entity.res;

public class Signature {
    private long expiresTime;
    private String signature;


    public Signature(String signature, int expiresIn) {
        this.signature=signature;
        expiresTime = System.currentTimeMillis()+expiresIn*1000;
    }

    public boolean isExpires(){
        return System.currentTimeMillis()>expiresTime;
    }

    public long getExpiresTime() {
        return expiresTime;
    }

    public void setExpiresTime(long expiresTime) {
        this.expiresTime = expiresTime;
    }

    public String getSignature() {
        return signature;
    }

    public void setSignature(String signature) {
        this.signature = signature;
    }
}
